<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">

<!-- 
	Copyright (C) 2007, 2008, 2009, 2010, 2011. PARP Research Group.
	<http://perception.inf.um.es>
	University of Murcia, Spain.

	This file is part of the QVision library.

	QVision is free software: you can redistribute it and/or modify
	it under the terms of the GNU Lesser General Public License as
	published by the Free Software Foundation, version 3 of the License.

	QVision is distributed in the hope that it will be useful,
	but WITHOUT ANY WARRANTY; without even the implied warranty of
	MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
	GNU Lesser General Public License for more details.

	You should have received a copy of the GNU Lesser General Public
	License along with QVision. If not, see <http://www.gnu.org/licenses/>.
-->

<html><head><meta http-equiv="content-Type" content="text/html;charset=UTF-8">
<title>QVision: Qt&#39;s Image, Video and Computer Vision Library</title>
<meta name="title" content="QVision" />
<meta name="dc.title" content="QVision" />
<meta name="url" content="http://perception.inf.um.es/QVision" />
<meta name="author" content="PARP Research Group - http://perception.inf.um.es" />
<meta name="revisit-after" content="30 DAYS"/>
<meta name="robots" content="index,follow"/>
<meta name="classification" content="*">
<meta name="rating" content="Safe For Kids">
<meta name="distribution" content="GLOBAL"/>
<meta name="description" content="Qt's Image, Video and Computer Vision Library"/>
<meta name="page-topic" content="Computer Vision research and prototype programming"/>
<meta name="geo.country" content="ES" />

<!--
Keywords:
By license:		open source, gnu, lgpl, gpl, free
By theme:		computer vision, image processing, robotics, programming, source, development
By usage:		library, toolkit, framework, prototype, application
By programming specs:	object oriented, c++, block programming, reusability, gui, graphical, parallel computing, high performance, GPU, prototyping
Interoperability with:	Qt, GSL, GNU Scientific library, OpenCV, CGAL, QWT, CUDA, mplayer, IPP, Intel Image Performance Primitives, blas, lapack
Functionallity:		image features, matrix algebra, projective geometry, mser, function minimization, function optimization, canny operator, harris operator, corner detection, performance evaluation, cpu usage, graphical interface
Main data-types:	matrix, vector, tensor, quaternion, image, polyline
Video sources:		webcam, camera, stream
Devices:		embedded, desktop computer, laptop, mini-laptop
Authors:		PARP research group. University of Murcia, Spain.
-->

<meta name="keywords" content="augmented reality, sfm, structure from motion, open source, gnu, lgpl, gpl, free, computer vision, image processing, robotics, programming, source, development, library, toolkit, framework, prototype, application, object oriented, c++, block programming, reusability, gui, graphical, parallel computing, high performance, GPU, prototyping, Qt, GSL, GNU Scientific library, OpenCV, CGAL, QWT, CUDA, mplayer, IPP, Intel Image Performance Primitives, blas, lapack, image features, matrix algebra, projective geometry, mser, function minimization, function optimization, canny operator, harris operator, corner detection, performance evaluation, cpu usage, graphical interface, matrix, vector, tensor, quaternion, image, polyline, webcam, camera, stream, embedded, desktop computer, laptop, mini-laptop, University of Murcia, Spain, PARP research group, vision por computador"/>
<meta http-equiv="keywords" content="augmented reality, sfm, structure from motion, open source, gnu, lgpl, gpl, free, computer vision, image processing, robotics, programming, source, development, library, toolkit, framework, prototype, application, object oriented, c++, block programming, reusability, gui, graphical, parallel computing, high performance, GPU, prototyping, Qt, GSL, GNU Scientific library, OpenCV, CGAL, QWT, CUDA, mplayer, IPP, Intel Image Performance Primitives, blas, lapack, image features, matrix algebra, projective geometry, mser, function minimization, function optimization, canny operator, harris operator, corner detection, performance evaluation, cpu usage, graphical interface, matrix, vector, tensor, quaternion, image, polyline, webcam, camera, stream, embedded, desktop computer, laptop, mini-laptop, University of Murcia, Spain, PARP research group, vision por computador"/>
<meta http-equiv="pragma" content="no-cache"/>
<meta http-equiv="title" content="QVision"/>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
<link href="tabs.css" rel="stylesheet" type="text/css" />
<link rel="shortcut icon" href="favicon.ico" />
</head><body>

<table width="100%"><tr>
	<td><a href="http://perception.inf.um.es/"><img src="parp.png" border="0" /> <big>PARP Research Group</big></a></td>
	<td align="right"><a href="http://www.um.es/"><big>Universidad de Murcia</big> <img src="um.png" border="0" /></a></td>
</tr></table>

<hr /><br />

<table width="95%" align="center"><tr><td>

<!-- Generated by Doxygen 1.6.3 -->
<script type="text/javascript"><!--
var searchBox = new SearchBox("searchBox", "search",false,'Search');
--></script>
<div class="navigation" id="top">
  <div class="tabs">
    <ul>
      <li><a href="index.html"><span>Main&nbsp;Page</span></a></li>
      <li><a href="pages.html"><span>Related&nbsp;Pages</span></a></li>
      <li><a href="modules.html"><span>Modules</span></a></li>
      <li><a href="annotated.html"><span>Classes</span></a></li>
      <li class="current"><a href="files.html"><span>Files</span></a></li>
      <li>
        <div id="MSearchBox" class="MSearchBoxInactive">
          <form id="FSearchBox" action="search.php" method="get">
            <img id="MSearchSelect" src="search/search.png" alt=""/>
            <input type="text" id="MSearchField" name="query" value="Search" size="20" accesskey="S" 
                   onfocus="searchBox.OnSearchFieldFocus(true)" 
                   onblur="searchBox.OnSearchFieldFocus(false)"/>
          </form>
        </div>
      </li>
    </ul>
  </div>
  <div class="tabs">
    <ul>
      <li><a href="files.html"><span>File&nbsp;List</span></a></li>
      <li><a href="globals.html"><span>File&nbsp;Members</span></a></li>
    </ul>
  </div>
<h1>src/qvmath/qvmatrix.h</h1><a href="qvmatrix_8h.html">Go to the documentation of this file.</a><div class="fragment"><pre class="fragment"><a name="l00001"></a>00001 <span class="comment">/*</span>
<a name="l00002"></a>00002 <span class="comment"> *      Copyright (C) 2007, 2008, 2009, 2010, 2011, 2012. PARP Research Group.</span>
<a name="l00003"></a>00003 <span class="comment"> *      &lt;http://perception.inf.um.es&gt;</span>
<a name="l00004"></a>00004 <span class="comment"> *      University of Murcia, Spain.</span>
<a name="l00005"></a>00005 <span class="comment"> *</span>
<a name="l00006"></a>00006 <span class="comment"> *      This file is part of the QVision library.</span>
<a name="l00007"></a>00007 <span class="comment"> *</span>
<a name="l00008"></a>00008 <span class="comment"> *      QVision is free software: you can redistribute it and/or modify</span>
<a name="l00009"></a>00009 <span class="comment"> *      it under the terms of the GNU Lesser General Public License as</span>
<a name="l00010"></a>00010 <span class="comment"> *      published by the Free Software Foundation, version 3 of the License.</span>
<a name="l00011"></a>00011 <span class="comment"> *</span>
<a name="l00012"></a>00012 <span class="comment"> *      QVision is distributed in the hope that it will be useful,</span>
<a name="l00013"></a>00013 <span class="comment"> *      but WITHOUT ANY WARRANTY; without even the implied warranty of</span>
<a name="l00014"></a>00014 <span class="comment"> *      MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the</span>
<a name="l00015"></a>00015 <span class="comment"> *      GNU Lesser General Public License for more details.</span>
<a name="l00016"></a>00016 <span class="comment"> *</span>
<a name="l00017"></a>00017 <span class="comment"> *      You should have received a copy of the GNU Lesser General Public</span>
<a name="l00018"></a>00018 <span class="comment"> *      License along with QVision. If not, see &lt;http://www.gnu.org/licenses/&gt;.</span>
<a name="l00019"></a>00019 <span class="comment"> */</span>
<a name="l00020"></a>00020 
<a name="l00024"></a>00024 
<a name="l00025"></a>00025 <span class="preprocessor">#ifndef QVMATRIX_H</span>
<a name="l00026"></a>00026 <span class="preprocessor"></span><span class="preprocessor">#define QVMATRIX_H</span>
<a name="l00027"></a>00027 <span class="preprocessor"></span>
<a name="l00028"></a>00028 <span class="preprocessor">#include &lt;iostream&gt;</span>
<a name="l00029"></a>00029 <span class="preprocessor">#include &lt;QVQuaternion&gt;</span>
<a name="l00030"></a>00030 <span class="preprocessor">#include &lt;QV3DPointF&gt;</span>
<a name="l00031"></a>00031 <span class="preprocessor">#include &lt;qvmath.h&gt;</span>
<a name="l00032"></a>00032 <span class="preprocessor">#include &lt;<a class="code" href="qvblasdatabuffer_8h.html" title="File from the QVision library.">qvmath/qvblasdatabuffer.h</a>&gt;</span>
<a name="l00033"></a>00033 
<a name="l00034"></a>00034 <span class="preprocessor">#ifdef QVOPENCV</span>
<a name="l00035"></a>00035 <span class="preprocessor"></span><span class="preprocessor">#include &lt;opencv/cv.h&gt;</span>
<a name="l00036"></a>00036 <span class="preprocessor">#endif</span>
<a name="l00037"></a>00037 <span class="preprocessor"></span>
<a name="l00038"></a>00038 <span class="preprocessor">#ifdef QVOCTAVE</span>
<a name="l00039"></a>00039 <span class="preprocessor"></span><span class="preprocessor">#include &lt;octave/oct.h&gt;</span>
<a name="l00040"></a>00040 <span class="preprocessor">#endif</span>
<a name="l00041"></a>00041 <span class="preprocessor"></span>
<a name="l00042"></a>00042 <span class="preprocessor">#ifdef _MSC_VER</span>
<a name="l00043"></a>00043 <span class="preprocessor"></span><span class="preprocessor">#ifdef max</span>
<a name="l00044"></a>00044 <span class="preprocessor"></span><span class="preprocessor">#undef max</span>
<a name="l00045"></a>00045 <span class="preprocessor"></span><span class="preprocessor">#endif // max</span>
<a name="l00046"></a>00046 <span class="preprocessor"></span>
<a name="l00047"></a>00047 <span class="preprocessor">#ifdef min</span>
<a name="l00048"></a>00048 <span class="preprocessor"></span><span class="preprocessor">#undef min</span>
<a name="l00049"></a>00049 <span class="preprocessor"></span><span class="preprocessor">#endif // min</span>
<a name="l00050"></a>00050 <span class="preprocessor"></span><span class="preprocessor">#endif // _MSC_VER</span>
<a name="l00051"></a>00051 <span class="preprocessor"></span>
<a name="l00052"></a>00052 <span class="comment">/*class QVArrayIndex</span>
<a name="l00053"></a>00053 <span class="comment">    {</span>
<a name="l00054"></a>00054 <span class="comment">    public:</span>
<a name="l00055"></a>00055 <span class="comment">        const QVMatrix *matrix;</span>
<a name="l00056"></a>00056 <span class="comment">        int row, col;</span>
<a name="l00057"></a>00057 <span class="comment">        QVArrayIndex(const QVMatrix &amp;matrix, const int col): matrix(&amp;matrix), row(-1), col(col) { };</span>
<a name="l00058"></a>00058 <span class="comment">    };*/</span>
<a name="l00059"></a>00059 
<a name="l00068"></a><a class="code" href="classQVMatrix.html">00068</a> <span class="keyword">class </span><a class="code" href="classQVMatrix.html" title="Implementation of numerical matrices.">QVMatrix</a>
<a name="l00069"></a>00069     {
<a name="l00070"></a>00070     <span class="keyword">public</span>:
<a name="l00071"></a>00071 
<a name="l00073"></a><a class="code" href="classQVMatrix.html#a8f4414e6cfd14fe164a164ab20379999">00073</a>         <span class="keyword">enum</span> <a class="code" href="classQVMatrix.html#a8f4414e6cfd14fe164a164ab20379999" title="Matrix types.">MatrixType</a>
<a name="l00074"></a>00074             {
<a name="l00076"></a><a class="code" href="classQVMatrix.html#a8f4414e6cfd14fe164a164ab20379999aeb4802be8c8da265afc8b204e41dfcd4">00076</a>             <a class="code" href="classQVMatrix.html#a8f4414e6cfd14fe164a164ab20379999aeb4802be8c8da265afc8b204e41dfcd4" title="General matrix.">General</a> = 0x00,
<a name="l00078"></a><a class="code" href="classQVMatrix.html#a8f4414e6cfd14fe164a164ab20379999a70d0ec7b265bc849efccd60db9c40a5a">00078</a>             <a class="code" href="classQVMatrix.html#a8f4414e6cfd14fe164a164ab20379999a70d0ec7b265bc849efccd60db9c40a5a" title="Symmetrix matrices.">Symmetric</a> = 0x01,
<a name="l00080"></a><a class="code" href="classQVMatrix.html#a8f4414e6cfd14fe164a164ab20379999a266e723ddafba230f9e674cb61c1a86d">00080</a>             <a class="code" href="classQVMatrix.html#a8f4414e6cfd14fe164a164ab20379999a266e723ddafba230f9e674cb61c1a86d" title="Upper triangular matrix.">UpperTriangular</a> = 0x2,
<a name="l00082"></a><a class="code" href="classQVMatrix.html#a8f4414e6cfd14fe164a164ab20379999ab550fa0060215d15361dfc059a2c19db">00082</a>                         <a class="code" href="classQVMatrix.html#a8f4414e6cfd14fe164a164ab20379999ab550fa0060215d15361dfc059a2c19db" title="Lower triangular matrix.">LowerTriangular</a> = 0x03,
<a name="l00084"></a><a class="code" href="classQVMatrix.html#a8f4414e6cfd14fe164a164ab20379999a73377bc14b613dbcf74b7d0215568481">00084</a>                         <a class="code" href="classQVMatrix.html#a8f4414e6cfd14fe164a164ab20379999a73377bc14b613dbcf74b7d0215568481" title="Diagonal matrix.">Diagonal</a> = 0x04,
<a name="l00086"></a><a class="code" href="classQVMatrix.html#a8f4414e6cfd14fe164a164ab20379999a68fb1d9ef0f816e806f50414659deb80">00086</a>                         <a class="code" href="classQVMatrix.html#a8f4414e6cfd14fe164a164ab20379999a68fb1d9ef0f816e806f50414659deb80" title="Permutation matrix.">PermutationMatrix</a> = 0x05
<a name="l00087"></a>00087                         };
<a name="l00088"></a>00088 
<a name="l00089"></a>00089         <span class="comment">/* Dot product for triangular matrices</span>
<a name="l00090"></a>00090 <span class="comment">        void dotProductLowerTriangular(const QVMatrix &amp;tr, QVMatrix &amp;A)</span>
<a name="l00091"></a>00091 <span class="comment">            {</span>
<a name="l00092"></a>00092 <span class="comment">            const int   m = A.getRows(), n = A.getCols();</span>
<a name="l00093"></a>00093 <span class="comment">            QVMatrix result(m, n);</span>
<a name="l00094"></a>00094 <span class="comment">            cblas_dtrmm(CblasRowMajor, CblasLeft, CblasLower, CblasTrans, CblasNonUnit, m, n, 1.0, tr.getReadData(), tr.getCols(), A.getWriteData(), A.getCols());</span>
<a name="l00095"></a>00095 <span class="comment">            }*/</span>
<a name="l00096"></a>00096 
<a name="l00097"></a>00097         <span class="comment">// Constructors</span>
<a name="l00102"></a>00102 <span class="comment"></span>        <a class="code" href="classQVMatrix.html#ab4f574a0822e8d707ca40970563338a3" title="Default constructor.">QVMatrix</a>();
<a name="l00103"></a>00103 
<a name="l00108"></a>00108         <a class="code" href="classQVMatrix.html#ab4f574a0822e8d707ca40970563338a3" title="Default constructor.">QVMatrix</a>(<span class="keyword">const</span> <a class="code" href="classQVMatrix.html" title="Implementation of numerical matrices.">QVMatrix</a> &amp;matrix);
<a name="l00109"></a>00109 
<a name="l00117"></a>00117         <a class="code" href="classQVMatrix.html#ab4f574a0822e8d707ca40970563338a3" title="Default constructor.">QVMatrix</a>(<span class="keyword">const</span> <span class="keywordtype">int</span> rows, <span class="keyword">const</span> <span class="keywordtype">int</span> cols, <span class="keyword">const</span> <span class="keywordtype">double</span> *data = NULL);
<a name="l00118"></a>00118 
<a name="l00126"></a>00126         <a class="code" href="classQVMatrix.html#ab4f574a0822e8d707ca40970563338a3" title="Default constructor.">QVMatrix</a>(<span class="keyword">const</span> <span class="keywordtype">int</span> rows, <span class="keyword">const</span> <span class="keywordtype">int</span> cols, <span class="keyword">const</span> <a class="code" href="classQVVector.html" title="Implementation of numerical vectors.">QVVector</a> &amp;data);
<a name="l00127"></a>00127 
<a name="l00135"></a>00135         <a class="code" href="classQVMatrix.html#ab4f574a0822e8d707ca40970563338a3" title="Default constructor.">QVMatrix</a>(<span class="keyword">const</span> <span class="keywordtype">int</span> rows, <span class="keyword">const</span> <span class="keywordtype">int</span> cols, <span class="keyword">const</span> <span class="keywordtype">double</span> value);
<a name="l00136"></a>00136 
<a name="l00143"></a>00143         <a class="code" href="classQVMatrix.html#ab4f574a0822e8d707ca40970563338a3" title="Default constructor.">QVMatrix</a>(<span class="keyword">const</span> <a class="code" href="classQVQuaternion.html" title="Implementation of quaternions.">QVQuaternion</a> &amp;quaternion);
<a name="l00144"></a>00144 
<a name="l00149"></a>00149 <span class="preprocessor">        #ifdef GSL_AVAILABLE</span>
<a name="l00150"></a>00150 <span class="preprocessor"></span>        <a class="code" href="classQVMatrix.html#ab4f574a0822e8d707ca40970563338a3" title="Default constructor.">QVMatrix</a>(<span class="keyword">const</span> gsl_matrix *matrix);
<a name="l00151"></a>00151 <span class="preprocessor">        #endif</span>
<a name="l00152"></a>00152 <span class="preprocessor"></span>
<a name="l00159"></a>00159 <span class="preprocessor">        #ifdef QVOPENCV</span>
<a name="l00160"></a>00160 <span class="preprocessor"></span>        <a class="code" href="classQVMatrix.html#ab4f574a0822e8d707ca40970563338a3" title="Default constructor.">QVMatrix</a>(<span class="keyword">const</span> CvMat *cvMatrix);
<a name="l00161"></a>00161 <span class="preprocessor">        #endif</span>
<a name="l00162"></a>00162 <span class="preprocessor"></span>
<a name="l00173"></a>00173 <span class="preprocessor">        #ifdef QVOPENCV</span>
<a name="l00174"></a>00174 <span class="preprocessor"></span>        CvMat *<a class="code" href="classQVMatrix.html#a129ef6e4e7854e7faa11234ac6686239" title="Converts the matrix to an OpenCV matrix structure.">toCvMat</a>(<span class="keyword">const</span> <span class="keywordtype">int</span> cvMatType = CV_64F) <span class="keyword">const</span>;
<a name="l00175"></a>00175 <span class="preprocessor">        #endif</span>
<a name="l00176"></a>00176 <span class="preprocessor"></span>
<a name="l00182"></a>00182 <span class="preprocessor">        #ifdef QVOPENCV</span>
<a name="l00183"></a><a class="code" href="classQVMatrix.html#a9dec7b945b360b936f42343d1993c73d">00183</a> <span class="preprocessor"></span>        <a class="code" href="classQVMatrix.html#a9dec7b945b360b936f42343d1993c73d" title="Converts the matrix to an OpenCV matrix structure.">operator CvMat *</a>()<span class="keyword"> const        </span>{ <span class="keywordflow">return</span> <a class="code" href="classQVMatrix.html#a129ef6e4e7854e7faa11234ac6686239" title="Converts the matrix to an OpenCV matrix structure.">toCvMat</a>(); }
<a name="l00184"></a>00184 <span class="preprocessor">        #endif</span>
<a name="l00185"></a>00185 <span class="preprocessor"></span>
<a name="l00192"></a>00192 <span class="preprocessor">        #ifdef QVOCTAVE</span>
<a name="l00193"></a>00193 <span class="preprocessor"></span>        <a class="code" href="classQVMatrix.html#ab4f574a0822e8d707ca40970563338a3" title="Default constructor.">QVMatrix</a>(<span class="keyword">const</span> Matrix octMatrix);
<a name="l00194"></a>00194 <span class="preprocessor">        #endif</span>
<a name="l00195"></a>00195 <span class="preprocessor"></span>
<a name="l00202"></a>00202 <span class="preprocessor">        #ifdef QVOCTAVE</span>
<a name="l00203"></a>00203 <span class="preprocessor"></span>        Matrix toOctaveMat() <span class="keyword">const</span>;
<a name="l00204"></a>00204 <span class="preprocessor">        #endif</span>
<a name="l00205"></a>00205 <span class="preprocessor"></span>
<a name="l00211"></a>00211 <span class="preprocessor">        #ifdef QVOCTAVE</span>
<a name="l00212"></a>00212 <span class="preprocessor"></span>        operator Matrix ()<span class="keyword"> const        </span>{ <span class="keywordflow">return</span> toOctaveMat(); }
<a name="l00213"></a>00213 <span class="preprocessor">        #endif</span>
<a name="l00214"></a>00214 <span class="preprocessor"></span>
<a name="l00221"></a>00221         <a class="code" href="classQVMatrix.html#ab4f574a0822e8d707ca40970563338a3" title="Default constructor.">QVMatrix</a>(<span class="keyword">const</span> <a class="code" href="classQVVector.html" title="Implementation of numerical vectors.">QVVector</a> &amp;vector, <span class="keyword">const</span> <span class="keywordtype">bool</span> rowVector = <span class="keyword">true</span>);
<a name="l00222"></a>00222 
<a name="l00228"></a>00228         <a class="code" href="classQVMatrix.html#ab4f574a0822e8d707ca40970563338a3" title="Default constructor.">QVMatrix</a>(<span class="keyword">const</span> QList&lt;QVVector&gt; &amp;vectorList);
<a name="l00229"></a>00229 
<a name="l00235"></a>00235         <a class="code" href="classQVMatrix.html#ab4f574a0822e8d707ca40970563338a3" title="Default constructor.">QVMatrix</a>(<span class="keyword">const</span> QList&lt; QVector&lt;double&gt; &gt; &amp;vectorList);
<a name="l00236"></a>00236 
<a name="l00242"></a>00242         <a class="code" href="classQVMatrix.html#ab4f574a0822e8d707ca40970563338a3" title="Default constructor.">QVMatrix</a>(<span class="keyword">const</span> QList&lt;QPointF&gt; &amp;pointList);
<a name="l00243"></a>00243 
<a name="l00246"></a>00246         <span class="comment">// Creates a new list of row QVVectors from a matrix</span>
<a name="l00247"></a><a class="code" href="classQVMatrix.html#a4f0eb74e2d2b71ba42ec6595527c71b4">00247</a>         <a class="code" href="classQVMatrix.html#a4f0eb74e2d2b71ba42ec6595527c71b4" title="Convert to a list of QVVectors operator.">operator QList&lt;QVVector&gt; </a>()<span class="keyword"> const</span>
<a name="l00248"></a>00248 <span class="keyword">            </span>{
<a name="l00249"></a>00249             QList&lt;QVVector&gt; list;
<a name="l00250"></a>00250             <span class="keywordflow">for</span> (<span class="keywordtype">int</span> n = 0; n &lt; <a class="code" href="classQVMatrix.html#a4108aa685baecab8a9822dcc04e98b7f" title="Get height of the matrix.">getRows</a>(); n++)
<a name="l00251"></a>00251                 list.append(<a class="code" href="classQVMatrix.html#ae27f08cd9a56a5c85ba2757cc4078d80" title="Gets a row of the matrix.">getRow</a>(n));
<a name="l00252"></a>00252             <span class="keywordflow">return</span> list;
<a name="l00253"></a>00253             }
<a name="l00254"></a>00254 
<a name="l00257"></a>00257         <span class="comment">// Creates a new list of row QVectors from a matrix</span>
<a name="l00258"></a><a class="code" href="classQVMatrix.html#a5482f998e122dcab127ce2bb18dbfcfc">00258</a>         <a class="code" href="classQVMatrix.html#a5482f998e122dcab127ce2bb18dbfcfc" title="Convert to a list of QVectors operator.">operator QList&lt; QVector&lt;double&gt; &gt; </a>()<span class="keyword"> const</span>
<a name="l00259"></a>00259 <span class="keyword">            </span>{
<a name="l00260"></a>00260             QList&lt; QVector&lt;double&gt; &gt; list;
<a name="l00261"></a>00261             <span class="keywordflow">for</span> (<span class="keywordtype">int</span> n = 0; n &lt; <a class="code" href="classQVMatrix.html#a4108aa685baecab8a9822dcc04e98b7f" title="Get height of the matrix.">getRows</a>(); n++)
<a name="l00262"></a>00262                 list.append(<a class="code" href="classQVMatrix.html#ae27f08cd9a56a5c85ba2757cc4078d80" title="Gets a row of the matrix.">getRow</a>(n));
<a name="l00263"></a>00263             <span class="keywordflow">return</span> list;
<a name="l00264"></a>00264             }
<a name="l00265"></a>00265 
<a name="l00270"></a>00270 <span class="preprocessor">        #ifdef GSL_AVAILABLE</span>
<a name="l00271"></a>00271 <span class="preprocessor"></span>        <a class="code" href="classQVMatrix.html#aeb271c920414baa68078052cd263d391" title="Convert to a gsl_matrix * operator.">operator gsl_matrix * </a>() <span class="keyword">const</span>;
<a name="l00272"></a>00272             <span class="comment">/*{</span>
<a name="l00273"></a>00273 <span class="comment">            gsl_matrix *result = gsl_matrix_alloc(rows, cols);</span>
<a name="l00274"></a>00274 <span class="comment">            for(int i = 0; i &lt; rows; i++)</span>
<a name="l00275"></a>00275 <span class="comment">                for(int j = 0; j &lt; cols; j++)</span>
<a name="l00276"></a>00276 <span class="comment">                    gsl_matrix_set(result, i, j, operator()(i, j));</span>
<a name="l00277"></a>00277 <span class="comment">            return result;</span>
<a name="l00278"></a>00278 <span class="comment">            }*/</span>
<a name="l00279"></a>00279 <span class="preprocessor">        #endif</span>
<a name="l00280"></a>00280 <span class="preprocessor"></span>
<a name="l00284"></a>00284         <a class="code" href="classQVMatrix.html" title="Implementation of numerical matrices.">QVMatrix</a> &amp; <a class="code" href="classQVMatrix.html#ad8121ca66a84f9d804f2e52764dc0fac" title="Copy operator.">operator=</a>(<span class="keyword">const</span> <a class="code" href="classQVMatrix.html" title="Implementation of numerical matrices.">QVMatrix</a> &amp;matrix);
<a name="l00285"></a>00285 
<a name="l00286"></a>00286         <span class="comment">// Matrix-matrix operators</span>
<a name="l00287"></a>00287 
<a name="l00293"></a><a class="code" href="classQVMatrix.html#a0475e20fe6c860e6188729afe78c6f72">00293</a>         <span class="keywordtype">bool</span> <a class="code" href="classQVMatrix.html#a0475e20fe6c860e6188729afe78c6f72" title="Matrix-matrix equality operator.">operator==</a>(<span class="keyword">const</span> <a class="code" href="classQVMatrix.html" title="Implementation of numerical matrices.">QVMatrix</a> &amp;matrix)<span class="keyword"> const                   </span>{ <span class="keywordflow">return</span> <a class="code" href="classQVMatrix.html#ad93605cfaa45a37fe579a709d3707ddf" title="Matrix-matrix equality operator.">equals</a>(matrix);        };
<a name="l00294"></a>00294 
<a name="l00300"></a><a class="code" href="classQVMatrix.html#a7eba7d4d45f9f23f32774871c442eb04">00300</a>         <a class="code" href="classQVMatrix.html" title="Implementation of numerical matrices.">QVMatrix</a> &amp; <a class="code" href="classQVMatrix.html#a7eba7d4d45f9f23f32774871c442eb04" title="Matrix-matrix incremental operator.">operator+=</a>(<span class="keyword">const</span> <a class="code" href="classQVMatrix.html" title="Implementation of numerical matrices.">QVMatrix</a> &amp;matrix)
<a name="l00301"></a>00301             {
<a name="l00302"></a>00302             <a class="code" href="classQVMatrix.html#a383f8068c7fe6e793807e20542f779d1" title="Matrix-matrix addition.">inlineAddition</a>(matrix);
<a name="l00303"></a>00303             <span class="keywordflow">return</span> *<span class="keyword">this</span>;
<a name="l00304"></a>00304             };
<a name="l00305"></a>00305 
<a name="l00311"></a><a class="code" href="classQVMatrix.html#aa54b4b5519dce590e7973f5d34dcc9ae">00311</a>         <span class="keywordtype">bool</span> <a class="code" href="classQVMatrix.html#aa54b4b5519dce590e7973f5d34dcc9ae" title="Matrix-matrix unequality operator.">operator!=</a>(<span class="keyword">const</span> <a class="code" href="classQVMatrix.html" title="Implementation of numerical matrices.">QVMatrix</a> &amp;matrix)<span class="keyword"> const                   </span>{ <span class="keywordflow">return</span> !<a class="code" href="classQVMatrix.html#ad93605cfaa45a37fe579a709d3707ddf" title="Matrix-matrix equality operator.">equals</a>(matrix);       };
<a name="l00312"></a>00312 
<a name="l00317"></a><a class="code" href="classQVMatrix.html#a6bf774fd020ec66c42f3f40659061079">00317</a>         <a class="code" href="classQVMatrix.html" title="Implementation of numerical matrices.">QVMatrix</a> <a class="code" href="classQVMatrix.html#a6bf774fd020ec66c42f3f40659061079" title="Matrix-matrix product operator.">operator*</a>(<span class="keyword">const</span> <a class="code" href="classQVMatrix.html" title="Implementation of numerical matrices.">QVMatrix</a> &amp;matrix)<span class="keyword"> const                </span>{ <span class="keywordflow">return</span> <a class="code" href="classQVMatrix.html#a5470e61c2827d5485596c3901690154c" title="Matrix-matrix product.">dotProduct</a>(matrix, <span class="keyword">false</span>, <span class="keyword">false</span>);      };
<a name="l00318"></a>00318 
<a name="l00345"></a>00345 <span class="preprocessor">                #ifdef QVMATRIXALGEBRA_AVAILABLE</span>
<a name="l00346"></a><a class="code" href="classQVMatrix.html#aa0424b2a59ca4be8687837ddae2afeab">00346</a> <span class="preprocessor"></span>        <a class="code" href="classQVMatrix.html" title="Implementation of numerical matrices.">QVMatrix</a> <a class="code" href="classQVMatrix.html#aa0424b2a59ca4be8687837ddae2afeab" title="Matrix-matrix division.">operator/</a>(<span class="keyword">const</span> <a class="code" href="classQVMatrix.html" title="Implementation of numerical matrices.">QVMatrix</a> &amp;matrix)<span class="keyword"> const                </span>{ <span class="keywordflow">return</span> <a class="code" href="classQVMatrix.html#a35e6590cf43e82694aa2b3d8e6559136" title="Matrix-matrix division.">matrixDivide</a>(matrix);  };
<a name="l00347"></a>00347 <span class="preprocessor">                #endif</span>
<a name="l00348"></a>00348 <span class="preprocessor"></span>
<a name="l00353"></a><a class="code" href="classQVMatrix.html#a1742df867662935c6aa02a22825baa9e">00353</a>         <a class="code" href="classQVMatrix.html" title="Implementation of numerical matrices.">QVMatrix</a> <a class="code" href="classQVMatrix.html#a1742df867662935c6aa02a22825baa9e" title="Matrix-matrix addition operator.">operator+</a>(<span class="keyword">const</span> <a class="code" href="classQVMatrix.html" title="Implementation of numerical matrices.">QVMatrix</a> &amp;matrix)<span class="keyword"> const                </span>{ <span class="keywordflow">return</span> <a class="code" href="classQVMatrix.html#abcbf2346a9cf0a62444d7a9254890952" title="Matrix-matrix addition.">addition</a>(matrix);      };
<a name="l00354"></a>00354 
<a name="l00359"></a><a class="code" href="classQVMatrix.html#af36e67dde2af09f40295af574cc2130b">00359</a>         <a class="code" href="classQVMatrix.html" title="Implementation of numerical matrices.">QVMatrix</a> <a class="code" href="classQVMatrix.html#af36e67dde2af09f40295af574cc2130b" title="Matrix-matrix substraction operator.">operator-</a>(<span class="keyword">const</span> <a class="code" href="classQVMatrix.html" title="Implementation of numerical matrices.">QVMatrix</a> &amp;matrix)<span class="keyword"> const                </span>{ <span class="keywordflow">return</span> <a class="code" href="classQVMatrix.html#ac65404c74ffc0f41f6d22a3fd6914f8a" title="Matrix-matrix substraction.">substract</a>(matrix);     };
<a name="l00360"></a>00360 
<a name="l00366"></a><a class="code" href="classQVMatrix.html#aa114573396ac3b3bc9ebaf975dc7ec9c">00366</a>         <a class="code" href="classQVMatrix.html" title="Implementation of numerical matrices.">QVMatrix</a> <a class="code" href="classQVMatrix.html#aa114573396ac3b3bc9ebaf975dc7ec9c" title="Obtains the additive inverse of the matrix.">operator-</a>()<span class="keyword"> const                                      </span>{ <span class="keywordflow">return</span> <a class="code" href="classQVMatrix.html#a6bf774fd020ec66c42f3f40659061079" title="Matrix-matrix product operator.">operator*</a>(-1.0);       };
<a name="l00367"></a>00367 
<a name="l00368"></a>00368         <span class="comment">// Matrix-scalar operators</span>
<a name="l00369"></a>00369 
<a name="l00374"></a><a class="code" href="classQVMatrix.html#af8943096382a045d930333b515bfcf8b">00374</a>         <a class="code" href="classQVMatrix.html" title="Implementation of numerical matrices.">QVMatrix</a> <a class="code" href="classQVMatrix.html#af8943096382a045d930333b515bfcf8b" title="Matrix-scalar product.">operator*</a>(<span class="keyword">const</span> <span class="keywordtype">double</span> value)<span class="keyword"> const                    </span>{ <span class="keywordflow">return</span> <a class="code" href="classQVMatrix.html#a75ac95f4f6c88b4354e4e8aeab5b13a1" title="Matrix-scalar product.">scalarProduct</a>(value);  };
<a name="l00375"></a>00375 
<a name="l00380"></a><a class="code" href="classQVMatrix.html#a747c925a4238317f16c26a4bafd64503">00380</a>         <a class="code" href="classQVMatrix.html" title="Implementation of numerical matrices.">QVMatrix</a> <a class="code" href="classQVMatrix.html#a747c925a4238317f16c26a4bafd64503" title="Matrix-scalar division operator.">operator/</a>(<span class="keyword">const</span> <span class="keywordtype">double</span> value)<span class="keyword"> const                    </span>{ <span class="keywordflow">return</span> <a class="code" href="classQVMatrix.html#ab87d29d63b8f41ff3f4a812a813f7718" title="Matrix-scalar division.">scalarDivide</a>(value);   };
<a name="l00381"></a>00381 
<a name="l00386"></a><a class="code" href="classQVMatrix.html#a49524200d6a4d2b01682239f176b9948">00386</a>         <a class="code" href="classQVMatrix.html" title="Implementation of numerical matrices.">QVMatrix</a> <a class="code" href="classQVMatrix.html#a49524200d6a4d2b01682239f176b9948" title="Matrix-scalar addition.">operator+</a>(<span class="keyword">const</span> <span class="keywordtype">double</span> value)<span class="keyword"> const                    </span>{ <span class="keywordflow">return</span> <a class="code" href="classQVMatrix.html#af1286b0c208cec68dd42e5411b210081" title="Matrix-scalar addition.">scalarAdd</a>(value);      };
<a name="l00387"></a>00387 
<a name="l00392"></a><a class="code" href="classQVMatrix.html#a349c6ab3c6b3a693df71ed1b787b0c67">00392</a>         <a class="code" href="classQVMatrix.html" title="Implementation of numerical matrices.">QVMatrix</a> <a class="code" href="classQVMatrix.html#a349c6ab3c6b3a693df71ed1b787b0c67" title="Matrix-scalar substraction operator.">operator-</a>(<span class="keyword">const</span> <span class="keywordtype">double</span> value)<span class="keyword"> const                    </span>{ <span class="keywordflow">return</span> <a class="code" href="classQVMatrix.html#a6980327fe32d68ae6028482a8a96200e" title="Matrix-scalar substraction.">scalarSubstract</a>(value);        };
<a name="l00393"></a>00393 
<a name="l00394"></a>00394         <span class="comment">// Matrix-vector operators</span>
<a name="l00395"></a>00395 
<a name="l00399"></a><a class="code" href="classQVMatrix.html#a60a80a735446038eec5b3ddaf8e8ed03">00399</a>         <a class="code" href="classQVVector.html" title="Implementation of numerical vectors.">QVVector</a> <a class="code" href="classQVMatrix.html#a60a80a735446038eec5b3ddaf8e8ed03" title="Matrix-vector product.">operator*</a>(<span class="keyword">const</span> <a class="code" href="classQVVector.html" title="Implementation of numerical vectors.">QVVector</a> &amp;vector)<span class="keyword"> const        </span>{ <span class="keywordflow">return</span> <a class="code" href="classQVMatrix.html#a5470e61c2827d5485596c3901690154c" title="Matrix-matrix product.">dotProduct</a>(vector, <span class="keyword">false</span>);     };
<a name="l00400"></a>00400 
<a name="l00401"></a>00401         <span class="comment">// Composition operators</span>
<a name="l00402"></a>00402 
<a name="l00411"></a>00411         <a class="code" href="classQVMatrix.html" title="Implementation of numerical matrices.">QVMatrix</a> <a class="code" href="classQVMatrix.html#aec43856676ac83417fcafda9d4ef57e5" title="Appends matrices vertically.">verticalAppend</a>(<span class="keyword">const</span> <a class="code" href="classQVMatrix.html" title="Implementation of numerical matrices.">QVMatrix</a> &amp;matrix) <span class="keyword">const</span>;
<a name="l00412"></a>00412 
<a name="l00413"></a>00413         <span class="comment">// Composition operators</span>
<a name="l00422"></a>00422 <span class="comment"></span>        <a class="code" href="classQVMatrix.html" title="Implementation of numerical matrices.">QVMatrix</a> <a class="code" href="classQVMatrix.html#a7b51282594521a3a7c759c7a43b5e73a" title="Appends matrices horizontally.">horizontalAppend</a>(<span class="keyword">const</span> <a class="code" href="classQVMatrix.html" title="Implementation of numerical matrices.">QVMatrix</a> &amp;matrix) <span class="keyword">const</span>;
<a name="l00423"></a>00423 
<a name="l00432"></a><a class="code" href="classQVMatrix.html#a03059f615e8ec998bfb35f22b23e1280">00432</a>         <a class="code" href="classQVMatrix.html" title="Implementation of numerical matrices.">QVMatrix</a> <a class="code" href="classQVMatrix.html#a03059f615e8ec998bfb35f22b23e1280" title="Appends matrices vertically.">operator&amp;</a>(<span class="keyword">const</span> <a class="code" href="classQVMatrix.html" title="Implementation of numerical matrices.">QVMatrix</a> &amp;matrix)<span class="keyword"> const        </span>{ <span class="keywordflow">return</span> <a class="code" href="classQVMatrix.html#aec43856676ac83417fcafda9d4ef57e5" title="Appends matrices vertically.">verticalAppend</a>(matrix); };
<a name="l00433"></a>00433 
<a name="l00442"></a><a class="code" href="classQVMatrix.html#a6decf507e131ab7fd704655277c004dd">00442</a>         <a class="code" href="classQVMatrix.html" title="Implementation of numerical matrices.">QVMatrix</a> <a class="code" href="classQVMatrix.html#a6decf507e131ab7fd704655277c004dd" title="Appends matrices horizontally.">operator|</a>(<span class="keyword">const</span> <a class="code" href="classQVMatrix.html" title="Implementation of numerical matrices.">QVMatrix</a> &amp;matrix)<span class="keyword"> const        </span>{ <span class="keywordflow">return</span> <a class="code" href="classQVMatrix.html#a7b51282594521a3a7c759c7a43b5e73a" title="Appends matrices horizontally.">horizontalAppend</a>(matrix); };
<a name="l00443"></a>00443 
<a name="l00452"></a><a class="code" href="classQVMatrix.html#a993620be472b4de818d58adba0c9ed4a">00452</a>         <a class="code" href="classQVMatrix.html" title="Implementation of numerical matrices.">QVMatrix</a> <a class="code" href="classQVMatrix.html#a993620be472b4de818d58adba0c9ed4a" title="Appends vector to matrix vertically.">operator&amp;</a>(<span class="keyword">const</span> <a class="code" href="classQVVector.html" title="Implementation of numerical vectors.">QVVector</a> &amp;vector)<span class="keyword"> const        </span>{ <span class="keywordflow">return</span> <a class="code" href="classQVMatrix.html#aec43856676ac83417fcafda9d4ef57e5" title="Appends matrices vertically.">verticalAppend</a>(<a class="code" href="classQVMatrix.html#ab4f574a0822e8d707ca40970563338a3" title="Default constructor.">QVMatrix</a>(vector)); };
<a name="l00453"></a>00453 
<a name="l00462"></a><a class="code" href="classQVMatrix.html#a63687cf86392096e1c43bfb429b57b1f">00462</a>         <a class="code" href="classQVMatrix.html" title="Implementation of numerical matrices.">QVMatrix</a> <a class="code" href="classQVMatrix.html#a63687cf86392096e1c43bfb429b57b1f" title="Appends vector to matrix horizontally.">operator|</a>(<span class="keyword">const</span> <a class="code" href="classQVVector.html" title="Implementation of numerical vectors.">QVVector</a> &amp;vector)<span class="keyword"> const        </span>{ <span class="keywordflow">return</span> <a class="code" href="classQVMatrix.html#a7b51282594521a3a7c759c7a43b5e73a" title="Appends matrices horizontally.">horizontalAppend</a>(<a class="code" href="classQVMatrix.html#ab4f574a0822e8d707ca40970563338a3" title="Default constructor.">QVMatrix</a>(vector).<a class="code" href="classQVMatrix.html#a2f87710c9d8ae4b07b03605daea3782e" title="Change the order of the indexes in the matrix.">transpose</a>()); };
<a name="l00463"></a>00463 
<a name="l00464"></a>00464         <span class="comment">// Operation methods</span>
<a name="l00465"></a>00465 
<a name="l00470"></a><a class="code" href="classQVMatrix.html#a7c4636a7c04ddacddb1cea2cbc1a5b60">00470</a>         <span class="keyword">inline</span> <span class="keywordtype">double</span> &amp;<a class="code" href="classQVMatrix.html#a7c4636a7c04ddacddb1cea2cbc1a5b60" title="Element access operator.">operator()</a>(<span class="keyword">const</span> <span class="keywordtype">int</span> row, <span class="keyword">const</span> <span class="keywordtype">int</span> col)
<a name="l00471"></a>00471             { <span class="keywordflow">return</span> data-&gt;getWriteData()[row*cols + col]; }
<a name="l00472"></a>00472 
<a name="l00477"></a><a class="code" href="classQVMatrix.html#a3166c3978b16d480038546163d087c3b">00477</a>         <span class="keyword">inline</span> <span class="keywordtype">double</span> <a class="code" href="classQVMatrix.html#a7c4636a7c04ddacddb1cea2cbc1a5b60" title="Element access operator.">operator()</a>(<span class="keyword">const</span> <span class="keywordtype">int</span> row, <span class="keyword">const</span> <span class="keywordtype">int</span> col)<span class="keyword"> const</span>
<a name="l00478"></a>00478 <span class="keyword">            </span>{ <span class="keywordflow">return</span> data-&gt;getReadData()[row*cols + col]; }
<a name="l00479"></a>00479 
<a name="l00484"></a><a class="code" href="classQVMatrix.html#ae9de904f46a790bef981c0101a4ee6f6">00484</a>         <span class="keywordtype">int</span> <a class="code" href="classQVMatrix.html#ae9de904f46a790bef981c0101a4ee6f6" title="Gets the size of the data array.">getDataSize</a>()<span class="keyword">                       const   </span>{ <span class="keywordflow">return</span> cols*rows; }
<a name="l00485"></a>00485 
<a name="l00489"></a><a class="code" href="classQVMatrix.html#a50de15cc657c8a1d9fcc749161192a64">00489</a>         <span class="keyword">const</span> <span class="keywordtype">double</span> *<a class="code" href="classQVMatrix.html#a50de15cc657c8a1d9fcc749161192a64" title="Gets a read-only reference to the data buffer of the matrix.">getReadData</a>()<span class="keyword">             const   </span>{ <span class="keywordflow">return</span> data-&gt;getReadData(); }
<a name="l00490"></a>00490 
<a name="l00494"></a><a class="code" href="classQVMatrix.html#a0c5b1e685d14d230c55cfcfb058e372a">00494</a>         <span class="keywordtype">double</span> *<a class="code" href="classQVMatrix.html#a0c5b1e685d14d230c55cfcfb058e372a" title="Gets a reference of the data buffer of the matrix for read and write accesses.">getWriteData</a>()                          { <span class="keywordflow">return</span> data-&gt;getWriteData(); }
<a name="l00495"></a>00495 
<a name="l00499"></a>00499         <a class="code" href="classQVMatrix.html" title="Implementation of numerical matrices.">QVMatrix</a> <a class="code" href="classQVMatrix.html#a2f87710c9d8ae4b07b03605daea3782e" title="Change the order of the indexes in the matrix.">transpose</a>() <span class="keyword">const</span>;
<a name="l00500"></a>00500 
<a name="l00504"></a>00504         <span class="keywordtype">void</span> <span class="keyword">set</span>(<span class="keyword">const</span> <span class="keywordtype">double</span> value);
<a name="l00505"></a>00505 
<a name="l00506"></a>00506         <span class="comment">// Matrix-matrix operations</span>
<a name="l00507"></a>00507 
<a name="l00514"></a>00514         <span class="keywordtype">bool</span> <a class="code" href="classQVMatrix.html#ad93605cfaa45a37fe579a709d3707ddf" title="Matrix-matrix equality operator.">equals</a>(<span class="keyword">const</span> <a class="code" href="classQVMatrix.html" title="Implementation of numerical matrices.">QVMatrix</a> &amp;matrix) <span class="keyword">const</span>;
<a name="l00515"></a>00515 
<a name="l00520"></a>00520         <a class="code" href="classQVMatrix.html" title="Implementation of numerical matrices.">QVMatrix</a> <a class="code" href="classQVMatrix.html#a5470e61c2827d5485596c3901690154c" title="Matrix-matrix product.">dotProduct</a>(<span class="keyword">const</span> <a class="code" href="classQVMatrix.html" title="Implementation of numerical matrices.">QVMatrix</a> &amp;matrix, <span class="keyword">const</span> <span class="keywordtype">bool</span> transposeFirstOperand = <span class="keyword">false</span>, <span class="keyword">const</span> <span class="keywordtype">bool</span> transposeSecondOperand = <span class="keyword">false</span>) <span class="keyword">const</span>;
<a name="l00521"></a>00521 
<a name="l00526"></a>00526         <a class="code" href="classQVVector.html" title="Implementation of numerical vectors.">QVVector</a> <a class="code" href="classQVMatrix.html#a5470e61c2827d5485596c3901690154c" title="Matrix-matrix product.">dotProduct</a>(<span class="keyword">const</span> <a class="code" href="classQVVector.html" title="Implementation of numerical vectors.">QVVector</a> &amp;vector, <span class="keyword">const</span> <span class="keywordtype">bool</span> transposeMatrix = <span class="keyword">false</span>) <span class="keyword">const</span>;
<a name="l00527"></a>00527 
<a name="l00534"></a>00534         <a class="code" href="classQVMatrix.html" title="Implementation of numerical matrices.">QVMatrix</a> <a class="code" href="classQVMatrix.html#a30f99ef8af0ff9f3997143d389698b71" title="Matrix-matrix element product.">elementProduct</a>(<span class="keyword">const</span> <a class="code" href="classQVMatrix.html" title="Implementation of numerical matrices.">QVMatrix</a> &amp;matrix) <span class="keyword">const</span>;
<a name="l00535"></a>00535 
<a name="l00545"></a>00545                 
<a name="l00548"></a>00548 <span class="preprocessor">                #ifdef QVMATRIXALGEBRA_AVAILABLE</span>
<a name="l00549"></a>00549 <span class="preprocessor"></span>        <a class="code" href="classQVMatrix.html" title="Implementation of numerical matrices.">QVMatrix</a> <a class="code" href="classQVMatrix.html#a35e6590cf43e82694aa2b3d8e6559136" title="Matrix-matrix division.">matrixDivide</a>(<span class="keyword">const</span> <a class="code" href="classQVMatrix.html" title="Implementation of numerical matrices.">QVMatrix</a> &amp;matrix) <span class="keyword">const</span>;
<a name="l00550"></a>00550 <span class="preprocessor">                #endif</span>
<a name="l00551"></a>00551 <span class="preprocessor"></span>
<a name="l00552"></a>00552 
<a name="l00553"></a>00553 
<a name="l00554"></a>00554 
<a name="l00555"></a>00555 
<a name="l00556"></a>00556 
<a name="l00557"></a>00557 
<a name="l00558"></a>00558 
<a name="l00559"></a>00559 
<a name="l00560"></a>00560 
<a name="l00561"></a>00561                 <span class="keywordtype">void</span> <a class="code" href="classQVMatrix.html#a051fa63dfff104d2705b793b4eb39213" title="Triangular system solving (vector of RHS).">triangularSolve</a>(<span class="keyword">const</span> <a class="code" href="classQVVector.html" title="Implementation of numerical vectors.">QVVector</a> &amp;b, <a class="code" href="classQVVector.html" title="Implementation of numerical vectors.">QVVector</a> &amp;x, <span class="keywordtype">bool</span> transposed = <span class="keyword">false</span>,
<a name="l00562"></a>00562                                          <span class="keywordtype">bool</span> unit_diagonal = <span class="keyword">false</span>) <span class="keyword">const</span>;
<a name="l00563"></a>00563 
<a name="l00574"></a>00574 <span class="preprocessor">                #ifdef BLAS_AVAILABLE</span>
<a name="l00575"></a>00575 <span class="preprocessor"></span>                <span class="keywordtype">void</span> <a class="code" href="classQVMatrix.html#a051fa63dfff104d2705b793b4eb39213" title="Triangular system solving (vector of RHS).">triangularSolve</a>(<span class="keyword">const</span> <a class="code" href="classQVMatrix.html" title="Implementation of numerical matrices.">QVMatrix</a> &amp;B, <a class="code" href="classQVMatrix.html" title="Implementation of numerical matrices.">QVMatrix</a> &amp;X, <span class="keywordtype">bool</span> transposed = <span class="keyword">false</span>,
<a name="l00576"></a>00576                                              <span class="keywordtype">bool</span> unit_diagonal = <span class="keyword">false</span>, <span class="keywordtype">bool</span> left = <span class="keyword">true</span>) <span class="keyword">const</span>;
<a name="l00577"></a>00577 <span class="preprocessor">                #endif</span>
<a name="l00578"></a>00578 <span class="preprocessor"></span>
<a name="l00581"></a>00581 <span class="preprocessor">                #ifdef QVMATRIXALGEBRA_AVAILABLE</span>
<a name="l00582"></a>00582 <span class="preprocessor"></span>                <a class="code" href="classQVMatrix.html" title="Implementation of numerical matrices.">QVMatrix</a> <a class="code" href="classQVMatrix.html#ab00a021c82b223c25b6d51c203e30d16" title="Computes the inverse of the matrix.">inverse</a>() <span class="keyword">const</span>;
<a name="l00583"></a>00583 <span class="preprocessor">                #endif</span>
<a name="l00584"></a>00584 <span class="preprocessor"></span>
<a name="l00587"></a>00587 <span class="preprocessor">                #ifdef QVMATRIXALGEBRA_AVAILABLE</span>
<a name="l00588"></a>00588 <span class="preprocessor"></span>                <span class="keywordtype">double</span> <a class="code" href="classQVMatrix.html#a340dd57c9cd0130521af15af550cfef2" title="Computes the determinant of the matrix.">det</a>() <span class="keyword">const</span>;
<a name="l00589"></a>00589 <span class="preprocessor">                #endif</span>
<a name="l00590"></a>00590 <span class="preprocessor"></span>
<a name="l00592"></a>00592         <a class="code" href="classQVVector.html" title="Implementation of numerical vectors.">QVVector</a> <a class="code" href="classQVMatrix.html#a065ea0cfb0a40679039c539bf4bb76b6" title="Obtains the mean vector for the column vectors in the matrix.">meanCol</a>() <span class="keyword">const</span>;
<a name="l00593"></a>00593 
<a name="l00598"></a>00598         <a class="code" href="classQVMatrix.html" title="Implementation of numerical matrices.">QVMatrix</a> <a class="code" href="classQVMatrix.html#abcbf2346a9cf0a62444d7a9254890952" title="Matrix-matrix addition.">addition</a>(<span class="keyword">const</span> <a class="code" href="classQVMatrix.html" title="Implementation of numerical matrices.">QVMatrix</a> &amp;matrix) <span class="keyword">const</span>;
<a name="l00599"></a>00599 
<a name="l00604"></a>00604         <span class="keywordtype">void</span> <a class="code" href="classQVMatrix.html#a383f8068c7fe6e793807e20542f779d1" title="Matrix-matrix addition.">inlineAddition</a>(<span class="keyword">const</span> <a class="code" href="classQVMatrix.html" title="Implementation of numerical matrices.">QVMatrix</a> &amp;matrix);
<a name="l00605"></a>00605 
<a name="l00610"></a>00610         <a class="code" href="classQVMatrix.html" title="Implementation of numerical matrices.">QVMatrix</a> <a class="code" href="classQVMatrix.html#ac65404c74ffc0f41f6d22a3fd6914f8a" title="Matrix-matrix substraction.">substract</a>(<span class="keyword">const</span> <a class="code" href="classQVMatrix.html" title="Implementation of numerical matrices.">QVMatrix</a> &amp;matrix) <span class="keyword">const</span>;
<a name="l00611"></a>00611 
<a name="l00612"></a>00612         <span class="comment">// Matrix-scalar operations</span>
<a name="l00613"></a>00613 
<a name="l00618"></a>00618         <a class="code" href="classQVMatrix.html" title="Implementation of numerical matrices.">QVMatrix</a> <a class="code" href="classQVMatrix.html#ab87d29d63b8f41ff3f4a812a813f7718" title="Matrix-scalar division.">scalarDivide</a>(<span class="keyword">const</span> <span class="keywordtype">double</span> value) <span class="keyword">const</span>;
<a name="l00619"></a>00619 
<a name="l00624"></a>00624         <a class="code" href="classQVMatrix.html" title="Implementation of numerical matrices.">QVMatrix</a> <a class="code" href="classQVMatrix.html#a75ac95f4f6c88b4354e4e8aeab5b13a1" title="Matrix-scalar product.">scalarProduct</a>(<span class="keyword">const</span> <span class="keywordtype">double</span> value) <span class="keyword">const</span>;
<a name="l00625"></a>00625 
<a name="l00630"></a>00630         <a class="code" href="classQVMatrix.html" title="Implementation of numerical matrices.">QVMatrix</a> <a class="code" href="classQVMatrix.html#af1286b0c208cec68dd42e5411b210081" title="Matrix-scalar addition.">scalarAdd</a>(<span class="keyword">const</span> <span class="keywordtype">double</span> value) <span class="keyword">const</span>;
<a name="l00631"></a>00631 
<a name="l00636"></a>00636         <a class="code" href="classQVMatrix.html" title="Implementation of numerical matrices.">QVMatrix</a> <a class="code" href="classQVMatrix.html#a6980327fe32d68ae6028482a8a96200e" title="Matrix-scalar substraction.">scalarSubstract</a>(<span class="keyword">const</span> <span class="keywordtype">double</span> value) <span class="keyword">const</span>;
<a name="l00637"></a>00637 
<a name="l00646"></a>00646         <span class="keywordtype">double</span> <a class="code" href="classQVMatrix.html#a387750529622104faba8047cb0efa62a" title="Gets the norm2 for matrix.">norm2</a>() <span class="keyword">const</span>;
<a name="l00647"></a>00647 
<a name="l00656"></a>00656         <span class="keywordtype">double</span> <a class="code" href="classQVMatrix.html#a9e57c222b6e0b0d8f43576b8ffc01e04" title="Gets the trace of the matrix.">trace</a>() <span class="keyword">const</span>;
<a name="l00657"></a>00657 
<a name="l00661"></a>00661         <span class="keywordtype">bool</span> <a class="code" href="classQVMatrix.html#a43455dfaf2e8fa71242ea1fdc8beb102" title="Checks whether the matrix contains a NaN value or not.">containsNaN</a>()      <span class="keyword">const</span>;
<a name="l00662"></a>00662 
<a name="l00666"></a>00666         <span class="keywordtype">bool</span> <a class="code" href="classQVMatrix.html#a6172be84a1ff456c4f39b37e6e3d3eaa" title="Checks whether the matrix contains an infinite value or not.">containsInf</a>()      <span class="keyword">const</span>;
<a name="l00667"></a>00667 
<a name="l00671"></a>00671         <span class="keywordtype">bool</span> <a class="code" href="classQVMatrix.html#aaaf9670f3170fdb0f609d6d08a75a05d" title="Checks whether the matrix is a diagonal matrix or not.">isDiagonal</a>()       <span class="keyword">const</span>;
<a name="l00672"></a>00672 
<a name="l00678"></a>00678         <a class="code" href="classQVMatrix.html" title="Implementation of numerical matrices.">QVMatrix</a> <a class="code" href="classQVMatrix.html#a12aec43704cd3577bea5fd127343aee0" title="Homogeneous normalization for rows of the matrix.">rowHomogeneousNormalize</a>() <span class="keyword">const</span>;
<a name="l00679"></a>00679 
<a name="l00683"></a><a class="code" href="classQVMatrix.html#a420bba03aeccbd18161418049a025f66">00683</a>         <span class="keywordtype">int</span> <a class="code" href="classQVMatrix.html#a420bba03aeccbd18161418049a025f66" title="Get width of the matrix.">getCols</a>()<span class="keyword"> const     </span>{ <span class="keywordflow">return</span> cols; }
<a name="l00684"></a>00684 
<a name="l00688"></a><a class="code" href="classQVMatrix.html#a4108aa685baecab8a9822dcc04e98b7f">00688</a>         <span class="keywordtype">int</span> <a class="code" href="classQVMatrix.html#a4108aa685baecab8a9822dcc04e98b7f" title="Get height of the matrix.">getRows</a>()<span class="keyword"> const     </span>{ <span class="keywordflow">return</span> rows; }
<a name="l00689"></a>00689 
<a name="l00696"></a><a class="code" href="classQVMatrix.html#a546d28cd3b62456bb4e09987c9904162">00696</a>         <a class="code" href="classQVMatrix.html#a8f4414e6cfd14fe164a164ab20379999" title="Matrix types.">MatrixType</a> <a class="code" href="classQVMatrix.html#a546d28cd3b62456bb4e09987c9904162" title="Get type of the matrix.">getType</a>()<span class="keyword"> const      </span>{ <span class="keywordflow">return</span> type; }
<a name="l00697"></a>00697 
<a name="l00704"></a><a class="code" href="classQVMatrix.html#a5ff2ac8ea4e316fc793d32ce09671e8c">00704</a>         <span class="keywordtype">void</span> <a class="code" href="classQVMatrix.html#a5ff2ac8ea4e316fc793d32ce09671e8c" title="Set type of the matrix.">setType</a>(<a class="code" href="classQVMatrix.html#a8f4414e6cfd14fe164a164ab20379999" title="Matrix types.">MatrixType</a> type)   { this-&gt;type = type; }
<a name="l00705"></a>00705 
<a name="l00711"></a><a class="code" href="classQVMatrix.html#a6d95db8050afcbb1336193a3b5b6573b">00711</a>         <span class="keyword">const</span> <a class="code" href="classQVMatrix.html" title="Implementation of numerical matrices.">QVMatrix</a> <a class="code" href="classQVMatrix.html#a420bba03aeccbd18161418049a025f66" title="Get width of the matrix.">getCols</a>(<span class="keyword">const</span> <span class="keywordtype">int</span> firstCol, <span class="keyword">const</span> <span class="keywordtype">int</span> lastCol)<span class="keyword"> const</span>
<a name="l00712"></a>00712 <span class="keyword">            </span>{
<a name="l00713"></a>00713             Q_ASSERT(-1 &lt; firstCol);
<a name="l00714"></a>00714             Q_ASSERT(lastCol &lt; <a class="code" href="classQVMatrix.html#a420bba03aeccbd18161418049a025f66" title="Get width of the matrix.">getCols</a>());
<a name="l00715"></a>00715             Q_ASSERT(firstCol &lt;= lastCol);
<a name="l00716"></a>00716 
<a name="l00717"></a>00717             <a class="code" href="classQVMatrix.html" title="Implementation of numerical matrices.">QVMatrix</a> result(<a class="code" href="classQVMatrix.html#a4108aa685baecab8a9822dcc04e98b7f" title="Get height of the matrix.">getRows</a>(), lastCol - firstCol + 1);
<a name="l00718"></a>00718             <span class="keywordflow">for</span> (<span class="keywordtype">int</span> i = 0; i &lt; <a class="code" href="classQVMatrix.html#a4108aa685baecab8a9822dcc04e98b7f" title="Get height of the matrix.">getRows</a>(); i++)
<a name="l00719"></a>00719                 <span class="keywordflow">for</span> (<span class="keywordtype">int</span> j = firstCol; j &lt;= lastCol; j++)
<a name="l00720"></a>00720                     result(i,j-firstCol) = <a class="code" href="classQVMatrix.html#a7c4636a7c04ddacddb1cea2cbc1a5b60" title="Element access operator.">operator()</a>(i,j);
<a name="l00721"></a>00721             <span class="keywordflow">return</span> result;
<a name="l00722"></a>00722             }
<a name="l00723"></a>00723 
<a name="l00729"></a><a class="code" href="classQVMatrix.html#a00e9802b334dca947733bf00ac049c5c">00729</a>         <span class="keyword">const</span> <a class="code" href="classQVMatrix.html" title="Implementation of numerical matrices.">QVMatrix</a> <a class="code" href="classQVMatrix.html#a4108aa685baecab8a9822dcc04e98b7f" title="Get height of the matrix.">getRows</a>(<span class="keyword">const</span> <span class="keywordtype">int</span> firstRow, <span class="keyword">const</span> <span class="keywordtype">int</span> lastRow)<span class="keyword"> const</span>
<a name="l00730"></a>00730 <span class="keyword">            </span>{
<a name="l00731"></a>00731             Q_ASSERT(-1 &lt; firstRow);
<a name="l00732"></a>00732             Q_ASSERT(lastRow &lt; <a class="code" href="classQVMatrix.html#a4108aa685baecab8a9822dcc04e98b7f" title="Get height of the matrix.">getRows</a>());
<a name="l00733"></a>00733             Q_ASSERT(firstRow &lt;= lastRow);
<a name="l00734"></a>00734 
<a name="l00735"></a>00735             <a class="code" href="classQVMatrix.html" title="Implementation of numerical matrices.">QVMatrix</a> result(lastRow - firstRow + 1, <a class="code" href="classQVMatrix.html#a420bba03aeccbd18161418049a025f66" title="Get width of the matrix.">getCols</a>());
<a name="l00736"></a>00736             <span class="keywordflow">for</span> (<span class="keywordtype">int</span> i = firstRow; i &lt;= lastRow; i++)
<a name="l00737"></a>00737                 <span class="keywordflow">for</span> (<span class="keywordtype">int</span> j = 0; j &lt; <a class="code" href="classQVMatrix.html#a420bba03aeccbd18161418049a025f66" title="Get width of the matrix.">getCols</a>(); j++)
<a name="l00738"></a>00738                     result(i-firstRow,j) = <a class="code" href="classQVMatrix.html#a7c4636a7c04ddacddb1cea2cbc1a5b60" title="Element access operator.">operator()</a>(i,j);
<a name="l00739"></a>00739             <span class="keywordflow">return</span> result;
<a name="l00740"></a>00740             }
<a name="l00741"></a>00741 
<a name="l00742"></a>00742         <span class="comment">// Access operations</span>
<a name="l00743"></a>00743 
<a name="l00748"></a>00748         <span class="keyword">const</span> <a class="code" href="classQVVector.html" title="Implementation of numerical vectors.">QVVector</a> <a class="code" href="classQVMatrix.html#ae27f08cd9a56a5c85ba2757cc4078d80" title="Gets a row of the matrix.">getRow</a>(<span class="keyword">const</span> <span class="keywordtype">int</span> row) <span class="keyword">const</span>;
<a name="l00749"></a>00749 
<a name="l00754"></a>00754         <span class="keywordtype">void</span> <a class="code" href="classQVMatrix.html#ad8684520b5095fb350022fc9acb0dba8" title="Sets a row of the matrix.">setRow</a>(<span class="keyword">const</span> <span class="keywordtype">int</span> row, <a class="code" href="classQVVector.html" title="Implementation of numerical vectors.">QVVector</a> vector);
<a name="l00755"></a>00755 
<a name="l00760"></a>00760         <span class="keywordtype">void</span> <a class="code" href="classQVMatrix.html#ad8684520b5095fb350022fc9acb0dba8" title="Sets a row of the matrix.">setRow</a>(<span class="keyword">const</span> <span class="keywordtype">int</span> row, QVector&lt;double&gt; vector);
<a name="l00761"></a>00761 
<a name="l00766"></a>00766         <span class="keyword">const</span> <a class="code" href="classQVVector.html" title="Implementation of numerical vectors.">QVVector</a> <a class="code" href="classQVMatrix.html#a476e9d1714f98c1ae1b7c1d396fcdbaa" title="Gets a column of the matrix.">getCol</a>(<span class="keyword">const</span> <span class="keywordtype">int</span> col) <span class="keyword">const</span>;
<a name="l00767"></a>00767 
<a name="l00772"></a>00772         <span class="keywordtype">void</span> <a class="code" href="classQVMatrix.html#a8ebc03603ced1c727afd6f3bd755e57a" title="Sets a column of the matrix.">setCol</a>(<span class="keyword">const</span> <span class="keywordtype">int</span> col, <a class="code" href="classQVVector.html" title="Implementation of numerical vectors.">QVVector</a> vector);
<a name="l00773"></a>00773 
<a name="l00781"></a>00781         <span class="keyword">const</span> <a class="code" href="classQVMatrix.html" title="Implementation of numerical matrices.">QVMatrix</a> <a class="code" href="classQVMatrix.html#a77b34335086bb9e12d7d72398c608e75" title="Gets a submatrix from a matrix.">getSubmatrix</a>(<span class="keyword">const</span> <span class="keywordtype">int</span> firstRow, <span class="keyword">const</span> <span class="keywordtype">int</span> lastRow, <span class="keyword">const</span> <span class="keywordtype">int</span> firstCol, <span class="keyword">const</span> <span class="keywordtype">int</span> lastCol) <span class="keyword">const</span>;
<a name="l00782"></a>00782 
<a name="l00788"></a>00788         <span class="keywordtype">void</span> <a class="code" href="classQVMatrix.html#ac5ce9ed25c533d7b89abe5b6a5c6df3e" title="Sets a submatrix from a matrix.">setSubmatrix</a>(<span class="keyword">const</span> <span class="keywordtype">int</span> row, <span class="keyword">const</span> <span class="keywordtype">int</span> col, <span class="keyword">const</span> <a class="code" href="classQVMatrix.html" title="Implementation of numerical matrices.">QVMatrix</a> &amp;M);
<a name="l00789"></a>00789 
<a name="l00793"></a>00793                 <a class="code" href="classQVMatrix.html" title="Implementation of numerical matrices.">QVMatrix</a> <a class="code" href="classQVMatrix.html#a8c360feaaf1382f1afeae554ca1af5b7" title="Gets a matrix with reversed rows (bottom to top).">reversedRows</a>() <span class="keyword">const</span>;
<a name="l00794"></a>00794 
<a name="l00798"></a>00798                 <a class="code" href="classQVMatrix.html" title="Implementation of numerical matrices.">QVMatrix</a> <a class="code" href="classQVMatrix.html#a9987d3595383ca057eeaad815845f00a" title="Gets a matrix with reversed columns (right to left).">reversedCols</a>() <span class="keyword">const</span>;
<a name="l00799"></a>00799 
<a name="l00803"></a>00803         <span class="keyword">const</span> <a class="code" href="classQVVector.html" title="Implementation of numerical vectors.">QVVector</a> <a class="code" href="classQVMatrix.html#abcfe032545b49448a2a064a7952f7ece" title="Gets the diagonal of the matrix.">diagonal</a>() <span class="keyword">const</span>;
<a name="l00804"></a>00804 
<a name="l00805"></a>00805         <span class="comment">// Misc matrices</span>
<a name="l00806"></a>00806 
<a name="l00810"></a>00810         <span class="keyword">static</span> <a class="code" href="classQVMatrix.html" title="Implementation of numerical matrices.">QVMatrix</a> <a class="code" href="classQVMatrix.html#a6eb15980d17c17d4a55ab09a77bcd715" title="Creates an identity matrix.">identity</a>(<span class="keyword">const</span> <span class="keywordtype">int</span> size);
<a name="l00811"></a>00811 
<a name="l00825"></a>00825         <span class="keyword">static</span> <a class="code" href="classQVMatrix.html" title="Implementation of numerical matrices.">QVMatrix</a> <a class="code" href="classQVMatrix.html#a953207e797ad5c2f8477d3507dbcf86b" title="Creates an intrinsic camera calibration matrix.">cameraCalibrationMatrix</a>(<span class="keyword">const</span> <span class="keywordtype">double</span> f, <span class="keyword">const</span> <span class="keywordtype">double</span> r = 1.0, <span class="keyword">const</span> <span class="keywordtype">double</span> cx = 0.0, <span class="keyword">const</span> <span class="keywordtype">double</span> cy = 0.0, <span class="keyword">const</span> <span class="keywordtype">double</span> s = 0.0);
<a name="l00826"></a>00826 
<a name="l00831"></a>00831         <span class="keyword">static</span> <a class="code" href="classQVMatrix.html" title="Implementation of numerical matrices.">QVMatrix</a> <a class="code" href="classQVMatrix.html#aa51c7a1ffb2ec8c9f56cd4c10ad61e81" title="Creates a zero matrix.">zeros</a>(<span class="keyword">const</span> <span class="keywordtype">int</span> rows, <span class="keyword">const</span> <span class="keywordtype">int</span> cols);
<a name="l00832"></a>00832 
<a name="l00839"></a>00839         <span class="keyword">static</span> <a class="code" href="classQVMatrix.html" title="Implementation of numerical matrices.">QVMatrix</a> <a class="code" href="classQVMatrix.html#ad2840553c7fa2cf81c8ce982db34b7b4" title="Creates a matrix of random values.">random</a>(<span class="keyword">const</span> <span class="keywordtype">int</span> rows, <span class="keyword">const</span> <span class="keywordtype">int</span> cols);
<a name="l00840"></a>00840 
<a name="l00844"></a>00844         <span class="keyword">static</span> <a class="code" href="classQVMatrix.html" title="Implementation of numerical matrices.">QVMatrix</a> <a class="code" href="classQVMatrix.html#abcfe032545b49448a2a064a7952f7ece" title="Gets the diagonal of the matrix.">diagonal</a>(<span class="keyword">const</span> <a class="code" href="classQVVector.html" title="Implementation of numerical vectors.">QVVector</a> &amp;diagonalVector);
<a name="l00845"></a>00845 
<a name="l00849"></a>00849         <span class="keyword">static</span> <a class="code" href="classQVMatrix.html" title="Implementation of numerical matrices.">QVMatrix</a> <a class="code" href="classQVMatrix.html#a34cc7d7a575e6e8f766d5e8d6f71ec70" title="Create a rotation matrix for points in the 2D plane.">rotationMatrix</a>(<span class="keyword">const</span> <span class="keywordtype">double</span> angle);
<a name="l00850"></a>00850 
<a name="l00855"></a>00855         <span class="keyword">static</span> <a class="code" href="classQVMatrix.html" title="Implementation of numerical matrices.">QVMatrix</a> <a class="code" href="classQVMatrix.html#a34cc7d7a575e6e8f766d5e8d6f71ec70" title="Create a rotation matrix for points in the 2D plane.">rotationMatrix</a>(<span class="keyword">const</span> QPointF center, <span class="keyword">const</span> <span class="keywordtype">double</span> angle);
<a name="l00856"></a>00856 
<a name="l00861"></a>00861         <span class="keyword">static</span> <a class="code" href="classQVMatrix.html" title="Implementation of numerical matrices.">QVMatrix</a> <a class="code" href="classQVMatrix.html#a0d4484ab18803104864a5da5a12e3231" title="Create a 2D translation matrix.">translationMatrix</a>(<span class="keyword">const</span> <span class="keywordtype">double</span> x, <span class="keyword">const</span> <span class="keywordtype">double</span> y);
<a name="l00862"></a>00862 
<a name="l00866"></a>00866         <span class="keyword">static</span> <a class="code" href="classQVMatrix.html" title="Implementation of numerical matrices.">QVMatrix</a> <a class="code" href="classQVMatrix.html#ae85e5758081def4123365e2b949e8028" title="Create a 2D scale matrix.">scaleMatrix</a>(<span class="keyword">const</span> <span class="keywordtype">double</span> zoom);
<a name="l00867"></a>00867 
<a name="l00871"></a>00871         <span class="keyword">static</span> <a class="code" href="classQVMatrix.html" title="Implementation of numerical matrices.">QVMatrix</a> <a class="code" href="classQVMatrix.html#a5b07abcac226018daecf7ed1251c79f4" title="Create a rotation matrix for 3D-X axis.">rotationMatrix3dXAxis</a>(<span class="keyword">const</span> <span class="keywordtype">double</span> angle);
<a name="l00872"></a>00872 
<a name="l00876"></a>00876         <span class="keyword">static</span> <a class="code" href="classQVMatrix.html" title="Implementation of numerical matrices.">QVMatrix</a> <a class="code" href="classQVMatrix.html#ac78ee1008505af7a88f864c74d14c454" title="Create a rotation matrix for 3D-Y axis.">rotationMatrix3dYAxis</a>(<span class="keyword">const</span> <span class="keywordtype">double</span> angle);
<a name="l00877"></a>00877 
<a name="l00881"></a>00881         <span class="keyword">static</span> <a class="code" href="classQVMatrix.html" title="Implementation of numerical matrices.">QVMatrix</a> <a class="code" href="classQVMatrix.html#afceda9ac099f725f7c44d47a4e7e9a9f" title="Create a rotation matrix for 3D-Z axis.">rotationMatrix3dZAxis</a>(<span class="keyword">const</span> <span class="keywordtype">double</span> angle);
<a name="l00882"></a>00882 
<a name="l00888"></a>00888         <span class="keyword">static</span> <a class="code" href="classQVMatrix.html" title="Implementation of numerical matrices.">QVMatrix</a> <a class="code" href="classQVMatrix.html#adcd15d700257dffdbf44cd015809dff0" title="Create a 3D translation matrix.">translationMatrix3d</a>(<span class="keyword">const</span> <span class="keywordtype">double</span> x, <span class="keyword">const</span> <span class="keywordtype">double</span> y, <span class="keyword">const</span> <span class="keywordtype">double</span> z);
<a name="l00889"></a>00889 
<a name="l00897"></a><a class="code" href="classQVMatrix.html#a8cb7e8779e6d1ed08b6ddb9e2fed9750">00897</a>         <a class="code" href="classQVMatrix.html" title="Implementation of numerical matrices.">QVMatrix</a> <a class="code" href="classQVMatrix.html#a8cb7e8779e6d1ed08b6ddb9e2fed9750" title="Create a new matrix with different size and the same content.">reshape</a>(<span class="keyword">const</span> <span class="keywordtype">int</span> newRows, <span class="keyword">const</span> <span class="keywordtype">int</span> newCols)<span class="keyword"> const</span>
<a name="l00898"></a>00898 <span class="keyword">            </span>{
<a name="l00899"></a>00899             <a class="code" href="classQVMatrix.html" title="Implementation of numerical matrices.">QVMatrix</a> result(newRows, newCols);
<a name="l00900"></a>00900             result.data = this-&gt;data;
<a name="l00901"></a>00901             <span class="keywordflow">return</span> result;
<a name="l00902"></a>00902             }
<a name="l00903"></a>00903 
<a name="l00908"></a><a class="code" href="classQVMatrix.html#a898e31e14b051d3795d3657b0091c577">00908</a>         <span class="keyword">static</span> <a class="code" href="classQVMatrix.html" title="Implementation of numerical matrices.">QVMatrix</a> <a class="code" href="classQVMatrix.html#a898e31e14b051d3795d3657b0091c577" title="Compute the product of a list of matrices.">multiply</a>(<span class="keyword">const</span> QList&lt;QVMatrix&gt; &amp;matrices)
<a name="l00909"></a>00909             {
<a name="l00910"></a>00910             <a class="code" href="classQVMatrix.html" title="Implementation of numerical matrices.">QVMatrix</a> product = <a class="code" href="classQVMatrix.html#a6eb15980d17c17d4a55ab09a77bcd715" title="Creates an identity matrix.">QVMatrix::identity</a>(3);
<a name="l00911"></a>00911             <span class="keywordflow">foreach</span>(<a class="code" href="classQVMatrix.html" title="Implementation of numerical matrices.">QVMatrix</a> matrix, matrices)
<a name="l00912"></a>00912                 product = product * matrix;
<a name="l00913"></a>00913             <span class="keywordflow">return</span> product;
<a name="l00914"></a>00914             }
<a name="l00915"></a>00915 
<a name="l00916"></a>00916     <span class="keyword">private</span>:
<a name="l00917"></a>00917         <span class="keywordtype">int</span> cols, rows;
<a name="l00918"></a>00918         <a class="code" href="classQVMatrix.html#a8f4414e6cfd14fe164a164ab20379999" title="Matrix types.">MatrixType</a> type;
<a name="l00919"></a>00919         <span class="keywordtype">bool</span> transposed;
<a name="l00920"></a>00920         QSharedDataPointer&lt; QBlasDataBuffer &gt; data;
<a name="l00921"></a>00921     };
<a name="l00922"></a>00922 
<a name="l00928"></a>00928 <a class="code" href="classQVMatrix.html" title="Implementation of numerical matrices.">QVMatrix</a> <a class="code" href="qvmatrix_8cpp.html#a487146b8bf0d9fa878ac70f07db27ba9" title="Matrix-scalar product.">operator*</a>(<span class="keyword">const</span> <span class="keywordtype">double</span> value, <span class="keyword">const</span> <a class="code" href="classQVMatrix.html" title="Implementation of numerical matrices.">QVMatrix</a> &amp;matrix);
<a name="l00929"></a>00929 
<a name="l00935"></a>00935 <a class="code" href="classQVMatrix.html" title="Implementation of numerical matrices.">QVMatrix</a> <a class="code" href="qvmatrix_8cpp.html#a7bd034eee5dffb1811c3012483e57f81" title="Matrix-scalar addition.">operator+</a>(<span class="keyword">const</span> <span class="keywordtype">double</span> value, <span class="keyword">const</span> <a class="code" href="classQVMatrix.html" title="Implementation of numerical matrices.">QVMatrix</a> &amp;matrix);
<a name="l00936"></a>00936 
<a name="l00942"></a>00942 <a class="code" href="classQVMatrix.html" title="Implementation of numerical matrices.">QVMatrix</a> <a class="code" href="qvmatrix_8cpp.html#a5f3ee33a44f26d22ea440be723fe2858" title="Matrix-scalar substraction operator.">operator-</a>(<span class="keyword">const</span> <span class="keywordtype">double</span> value, <span class="keyword">const</span> <a class="code" href="classQVMatrix.html" title="Implementation of numerical matrices.">QVMatrix</a> &amp;matrix);
<a name="l00943"></a>00943 
<a name="l00946"></a>00946 std::ostream&amp; operator &lt;&lt; ( std::ostream &amp;os, <span class="keyword">const</span> <a class="code" href="classQVMatrix.html" title="Implementation of numerical matrices.">QVMatrix</a> &amp;matrix );
<a name="l00947"></a>00947 
<a name="l00950"></a>00950 std::istream&amp; <a class="code" href="group__qvmath.html#ga20cb79175099f4623dc53a96d9f1ce6c">operator &gt;&gt; </a>( std::istream &amp;is, <a class="code" href="classQVMatrix.html" title="Implementation of numerical matrices.">QVMatrix</a> &amp;matrix );
<a name="l00951"></a>00951 
<a name="l00954"></a>00954 uint qHash(<span class="keyword">const</span> <a class="code" href="classQVMatrix.html" title="Implementation of numerical matrices.">QVMatrix</a> &amp;matrix);
<a name="l00955"></a>00955 
<a name="l00956"></a>00956 <span class="preprocessor">#include &lt;QString&gt;</span>
<a name="l00967"></a>00967 <span class="keywordtype">bool</span> <a class="code" href="group__qvmath.html#ga9ead752411a6772cfd7d75051cdc677e" title="Writes the content of a QVMatrix object in an ASCII file.">writeQVMatrixToFile</a>(<span class="keyword">const</span> QString fileName, <span class="keyword">const</span> <a class="code" href="classQVMatrix.html" title="Implementation of numerical matrices.">QVMatrix</a> &amp;matrix, <span class="keyword">const</span> <span class="keywordtype">int</span> precission = 7);
<a name="l00976"></a>00976 <span class="keywordtype">bool</span> <a class="code" href="group__qvmath.html#gae1e1afa78741e92ed46d20b70830a4fc" title="Reads the content of a QVMatrix object from an ASCII file.">readQVMatrixFromFile</a>(<span class="keyword">const</span> QString fileName, <a class="code" href="classQVMatrix.html" title="Implementation of numerical matrices.">QVMatrix</a> &amp;matrix);
<a name="l00977"></a>00977 
<a name="l00997"></a>00997 <a class="code" href="classQV3DPointF.html" title="3D point representation">QV3DPointF</a> <a class="code" href="group__qvmath.html#ga85e11a75a24eec1686a939aa690e1942" title="Obtains the element from the Lie algebra so(3) corresponding to a rotation matrix...">lnSO3</a>(<span class="keyword">const</span> <a class="code" href="classQVMatrix.html" title="Implementation of numerical matrices.">QVMatrix</a> &amp;R);
<a name="l00998"></a>00998 
<a name="l01018"></a>01018 <a class="code" href="classQVMatrix.html" title="Implementation of numerical matrices.">QVMatrix</a> <a class="code" href="group__qvmath.html#gad9a79664f7af4487d5af8fe2296fc7a4" title="Obtains the rotation matrix corresponding to the element from the Lie algebra so(3)...">expSO3</a>(<span class="keyword">const</span> <a class="code" href="classQV3DPointF.html" title="3D point representation">QV3DPointF</a>&amp; w);
<a name="l01019"></a>01019 
<a name="l01020"></a>01020 <span class="preprocessor">#include &lt;QMetaType&gt;</span>
<a name="l01021"></a>01021 Q_DECLARE_METATYPE(<a class="code" href="classQVMatrix.html" title="Implementation of numerical matrices.">QVMatrix</a>);
<a name="l01022"></a>01022 
<a name="l01023"></a>01023 <span class="preprocessor">#endif</span>
<a name="l01024"></a>01024 <span class="preprocessor"></span>
</pre></div></div>
</td></tr></table>

<br /><hr><br />
<center><a href="http://perception.inf.um.es/QVision">QVision framework</a>.
<a href="http://perception.inf.um.es">PARP research group</a>.
Copyright &copy; 2007, 2008, 2009, 2010, 2011.</center>
<br />
</body>
</html>
